package com.monlyu.vo;

import java.math.BigDecimal;
import java.util.Date;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;

import com.monlyu.annotation.Comment;

/********************************************************************************
 * 
 * <b>功能描述☞</b>外出申请单<br>
 * 
 * <b>开发公司☞</b>重庆唯尼科技有限公司<br>
 * <b>版权☞</b>本文件归重庆唯尼科技有限公司所有<br>
 * <b>项目名☞</b>NewsSys<br>
 * <b>文件路径☞</b>com.monlyu.vo.OuterApp.java<br>
 * <b>开发日期☞</b>2010-2-9 <br>
 * 
 * @author monlyu
 * @since JDK 5
 * @version 1.0.8
 * 
 ********************************************************************************/
@Entity(name = "t_outapp")
@Comment(common = "外出申请表")
public class OuterApp extends BaseVo {

	/** 草稿 */
	public static final int STATUS_DRAFT = 0;
	/** 待审核 */
	public static final int STATUS_AUDITING = 1;
	/** 审核完毕 */
	public static final int STATUS_DONE = 2;
	/** 审核未通过 */
	public static final int STATUS_NOTPASS = 3;

	public static final int STATUS_ZHIPAI_TMP = -1;

	@Id
	@Column(name = "o_id")
	@Comment(common = "编号")
	private Long id;

	@ManyToOne
	@JoinColumn(name = "o_apper")
	@Comment(common = "申请人")
	private User apper;

	@Column(name = "o_status")
	@Comment(common = "申请单状态")
	private int status;

	@Column(name = "o_tvon")
	@Comment(common = "所属栏目编号")
	private Long tvon;

	@Column(name = "o_msgFrom")
	@Comment(common = "消息来源")
	private Long msgFrom;

	@Column(name = "o_begin")
	@Comment(common = "开始时间")
	private Date begin;

	@Column(name = "o_end")
	@Comment(common = "结束时间")
	private Date end;

	@Column(name = "o_where")
	@Comment(common = "地域编号")
	private Long where;

	@Column(name = "o_used")
	@Comment(common = "用途编号")
	private Long used;

	@Column(name = "o_theme", length = MAX_VCHAR_MYSQL)
	@Comment(common = "采访主题")
	private String theme;

	@Column(name = "o_comment", length = MAX_VCHAR_MYSQL)
	@Comment(common = "申请备注")
	private String comment;

	@Column(name = "o_device", length = MAX_VCHAR_MYSQL)
	@Comment(common = "需要的设备类型")
	private String device;

	@ManyToOne
	@JoinColumn(name = "o_userId")
	@Comment(common = "审批人")
	private User aduitor;

	@Column(name = "o_audit")
	@Comment(common = "审核日期")
	private Date auditDate;

	@Column(name = "o_aduitMsg", length = MAX_VCHAR_MYSQL)
	@Comment(common = "审核意见")
	private String aduitMsg;

	@Column(name = "o_aduitDevMsg", length = MAX_VCHAR_MYSQL)
	@Comment(common = "设备审核意见")
	private String aduitDevMsg;

	@Column(name = "o_grants")
	@Comment(common = "车费补助金额")
	private BigDecimal grants;

	@Column(name = "o_givedDevices", length = MAX_VCHAR_MYSQL)
	@Comment(common = "分配的设备")
	private String givedDevices;

	@Column(name = "o_joiner", length = MAX_VCHAR_MYSQL)
	@Comment(common = "参与者的id编号")
	private String joiner;

	@Column(name = "o_date")
	@Comment(common = "申请时间")
	private Date date;

	public Date getDate() {
		return date;
	}

	public void setDate(Date date) {
		this.date = date;
	}

	public String getJoiner() {
		return joiner;
	}

	public void setJoiner(String joiner) {
		this.joiner = joiner;
	}

	public String getGivedDevices() {
		return givedDevices;
	}

	public void setGivedDevices(String givedDevices) {
		this.givedDevices = givedDevices;
	}

	public Long getId() {
		return id;
	}

	public void setId(Long id) {
		this.id = id;
	}

	public User getApper() {
		return apper;
	}

	public void setApper(User apper) {
		this.apper = apper;
	}

	public int getStatus() {
		return status;
	}

	public void setStatus(int status) {
		this.status = status;
	}

	public Long getTvon() {
		return tvon;
	}

	public void setTvon(Long tvon) {
		this.tvon = tvon;
	}

	public Long getMsgFrom() {
		return msgFrom;
	}

	public void setMsgFrom(Long msgFrom) {
		this.msgFrom = msgFrom;
	}

	public Date getBegin() {
		return begin;
	}

	public void setBegin(Date begin) {
		this.begin = begin;
	}

	public Date getEnd() {
		return end;
	}

	public void setEnd(Date end) {
		this.end = end;
	}

	public Long getWhere() {
		return where;
	}

	public void setWhere(Long where) {
		this.where = where;
	}

	public Long getUsed() {
		return used;
	}

	public void setUsed(Long used) {
		this.used = used;
	}

	public String getTheme() {
		return theme;
	}

	public void setTheme(String theme) {
		this.theme = theme;
	}

	public String getComment() {
		return comment;
	}

	public void setComment(String comment) {
		this.comment = comment;
	}

	public String getDevice() {
		return device;
	}

	public void setDevice(String device) {
		this.device = device;
	}

	public Date getAudit() {
		return auditDate;
	}

	public void setAudit(Date audit) {
		this.auditDate = audit;
	}

	public BigDecimal getGrants() {
		return grants;
	}

	public void setGrants(BigDecimal grants) {
		this.grants = grants;
	}

	public String getAduitMsg() {
		return aduitMsg;
	}

	public void setAduitMsg(String aduitMsg) {
		this.aduitMsg = aduitMsg;
	}

	public String getAduitDevMsg() {
		return aduitDevMsg;
	}

	public void setAduitDevMsg(String aduitDevMsg) {
		this.aduitDevMsg = aduitDevMsg;
	}

	public User getAduitor() {
		return aduitor;
	}

	public Date getAuditDate() {
		return auditDate;
	}

	public void setAuditDate(Date auditDate) {
		this.auditDate = auditDate;
	}

	public void setAduitor(User aduitor) {
		this.aduitor = aduitor;
	}
}